<template>
    <view class="back-wrap" :style="{ top: statusBarH + 'px' }">
        <text class="iconfont icon-fenxiang1-copy" @click="onBackHandle"></text>
    </view>
</template>

<script setup>
import { onLoad } from '@dcloudio/uni-app';
import { ref } from 'vue';
const statusBarH = ref(0);
const titleH = ref(0);
onLoad(() => {
    const sysInfo = uni.getSystemInfoSync();
    const { statusBarHeight } = sysInfo;
    const { height, top } = uni.getMenuButtonBoundingClientRect();
    statusBarH.value = statusBarHeight;
    titleH.value = (top - statusBarHeight) * 2 + height;
})

const onBackHandle = () => {
    uni.navigateBack()
}
</script>
<style>
.icon-fenxiang1-copy {
    font-size: 30rpx;
}
</style>
<style lang="scss" scoped>
.back-wrap {
    position: absolute;
    left: 20rpx;
    width: 60rpx;
    height: 60rpx;
    z-index: 999;
    background-color: rgba(0, 0, 0, .4);
    border-radius: 30rpx;
    line-height: 60rpx;
    text-align: center;
}
</style>